#ifndef __ASFTDATASCREEN_H__
#define __ASFTDATASCREEN_H__

#include "ASScreen.h"
#include "ASScreenShare.h"
#include "..\app\ASFTData.h"
#include "..\control\ASButton.h"
#include "..\control\ASList.h"
#include "..\control\ASTableBar.h"
#include "..\control\ASScrollText.h"

typedef enum
{
    AS_FT_NEW_REC,
    AS_FT_EDIT_REC,

    AS_FT_ACTION_TO_REC_MAX
} as_ft_data_action_type;

typedef enum
{
    AS_FT_REC_ACTION_EDIT,
    AS_FT_REC_ACTION_DELETE,

    AS_FT_REC_ACTION_EDIT_TYPE_MAX
} as_ft_data_edit_type;

typedef enum
{
    AS_FT_SCR_LABEL_HEAD,
    AS_FT_SCR_LABEL_SUBTITLE,
    AS_FT_SCR_LABEL_EDIT,

    AS_FT_SCR_LABEL_MAX
} as_ftdata_screen_label;

typedef struct
{
    as_screen base;
    //as_ft_main_data main_data;
    as_button *lsk, *rsk;
    as_list* list;
    as_scrolltext* account_text;
    as_scrolltext* money_text;
    as_scrolltext* time_text;
    as_scrolltext* comment_text;
    as_scrolltext* member_text;
    as_scrolltext* money_type_text;

    ASCHAR tmp_str[64];
    ASWCHAR type_str[64];

} as_ftdata_screen;

void as_ftdata_screen_init(as_screen* screen_p);
void as_ftdata_screen_deinit(as_screen* screen_p);

void as_ftdata_screen_update_money(void);
ASUINT64* as_ftdata_screen_get_money(void);

void as_ftdata_screen_update_time(void);
as_time* as_ftdata_screen_get_time(void);
ASCHAR* as_ftdata_screen_get_time_str(as_time* time_p);

ASINT as_ftdata_screen_get_member(void);
void as_ftdata_screen_set_member(ASINT member);
ASWCHAR* as_ftdata_screen_get_member_str(void);

ASINT as_ftdata_screen_get_moneytype_top(void);
void as_ftdata_screen_set_moneytype_top(ASINT pay_top);
ASWCHAR* as_ftdata_screen_get_moneytype_top_str(void);

ASINT as_ftdata_screen_get_moneytype_sub(void);
void as_ftdata_screen_set_moneytype_sub(ASINT pay_sub);
ASWCHAR* as_ftdata_screen_get_moneytype_sub_str(void);

ASWCHAR* as_ftdata_screen_get_moneytype_str(void);

ASINT as_ftdata_screen_get_type(void);
void as_ftdata_screen_set_type(ASINT type);
ASWCHAR* as_ftdata_screen_get_type_str(void);

as_ft_main_data* as_ftdata_screen_get_main_data(void);
void as_ft_enter_new_data_screen(void);
void as_ft_enter_edit_data_screen(void);
void as_ft_screen_prepare_enter_edit_screen(as_time time_for_file, ASINT idx, as_void_func ok_func);
#endif //__ASFTDATASCREEN_H__